<extend name="Public/layout"/>
<block name="head">
    <link rel="stylesheet" href="__PUBLIC__css/apply-pusher.css">
        <style type="text/css">
        .footer{
            display: none;
        }
        </style>
</block>
<block name="main">
    <div class="apply-top">
        <div class="applt-top-bg">
            <h3>申请成为理财投顾</h3>
            <p>理财知识共享 用理财知识创造财富</p>
        </div>
        <h3>投顾优势</h3>
        <ul class="list-wrapper">
            <li class="list-item">
                <p>邀请徒弟可获得8号返利</p>
            </li>
            <li class="list-item">
                <p>可自由设置投资奖励红包</p>
            </li>
            <li class="list-item">
                <p>建立个人知识体系，分享投资经验</p>
            </li>
            <li class="list-item">
                <p>个性化专属个人主页</p>
            </li>
            <li class="list-item">
                <p>多个平台，一个返利账户搞定</p>
            </li>
            <li class="list-item">
                <p>成为正式投顾即可提现推广返利</p>
            </li>
        </ul>
    </div>
    <!-- <div class="apply-middle">
        <h3>成为投顾流程</h3>
        <div class="bg-wrapper">
            <img src="__PUBLIC__images/apply-pusher-steps.png" alt="">
        </div>
    </div> -->
    <div class="apply-bottom">
        <p>在线客服：请添加QQ1000828</p>
        <p>客服热线：请拨打400-999-2337</p>
    </div>
    <div class="apply-btn-wrapper">
        <a href="javascript:" onclick="apply()">申请成为投顾</a>
    </div>
</block>
<block name="js">
    <script>

function apply(){
    var user_id = "{$_SESSION['user']['id']}";
    if(user_id) {
            $.post('{:U("Recommend/ajax_push_reg")}',{user_id:user_id},function(res) {
                if(res.err==0) {
                    var id_card = "{$_SESSION['user']['card_status']}";
                    if(id_card==1) {
                        location.href="{:U('Recommend/push_apply')}";
                    } else {
                        location.href="{:U('Recommend/apply_pusher_form')}";
                    }
                } else {
                    layer.open({
                        content:res.msg
                        ,skin: 'msg'
                        ,time: 1.5
                    });
                }
            });
    } else {
        layer.open({
            content:"请先登录"
            ,skin: 'msg'
            ,time: 1
            ,end: function() {
                location.href="/Home/User/login?callback=/Home/Recommend/apply_pusher";
            }
        });
    }
}

    </script>
</block>